<{include file="section/admin/admin_header.tpl"}>
<body>
<{include file="section/admin/admin_header_login_bar.tpl"}>
<div id="contentA" class="clear">
	<!--leftsidebar sr-->
	<{include file="section/admin/admin_left_sidebar.tpl"}>
    <!--/leftsidebar end-->
    <div class="rightCont">
    	<!--path st-->
		<div class="path">您的位置：<a href="/">首页</a>&gt; <a href="/task/list">任务管理</a>&gt; 创建任务</div>
		<!--/path end-->
		
		<{$message}>

    	<h2 class="title01"><span>创建任务</span></h2>
        <div class="line1"></div>
		<div class="boxform">
			<form action="/task/create" method="post" name="frm" id="frm">
			<input type="hidden" name="action" value="">
            <ul class="clear">
            <li class="i1"><span class="red">*</span> 账　　号：</li>
            <li><span class="in"><input type="text" name="login_name" class="in2" onblur="this.className='in2'" onfocus="this.className='in1'" value="" style="width:177px;" /></span></li>
            </ul>
            <ul class="clear">
            <li class="i1"><span class="red">*</span> 对　象ID：</li>
            <li><span class="in"><input type="text" name="obj_id" class="in2" onblur="this.className='in2'" onfocus="this.className='in1'" value="" style="width:177px;" /></span></li>
			</ul>
            <ul class="clear">
            <li class="i1"><span class="red">*</span> 类　　型：</li>
            <li><span class="in">           
			<select class="in2" name="type" onblur="this.className='in2'" onfocus="this.className='in1'" style="width:177px;" >
			<{foreach from=$types item=data key=key}>
                    <option value="<{$data.task_type}>,<{$data.model_name}>" ><{$data.display_name}></option>
			<{/foreach}>
			</select>
			</span></li> 
			</ul>
			<ul class="clear">
			<li class="i1"><span class="red"> &nbsp;</span> 描　　述：</li>
			<li><span class="in"><textarea name="desc" class="in2" onblur="this.className='in2'" onfocus="this.className='in1'" value="" style="width:177px;" /></textarea></span></li>
			</ul>
            <div class="line margin25"></div>
            <ul class="clear">
            <li class="i1">&nbsp;</li>
            <li>
            	<input type="submit" class="btn04" value="确　定"/>　<input type="reset" class="btn04" value="取　消" />
            </li>
            </ul>
			</form>
        </div>
        
    </div>
</div>
</body>
<script type="text/javascript">
var frm = document.getElementById('frm');
frm.onsubmit = function ()
{
	with(this)
	{
		if(login_name.value == '')
		{
			ymPrompt.errorInfo('请填写帐号',null,null,'错误提示',function(){ymPrompt.close();login_name.focus();});
			return false;
		}
		if(obj_id.value == '')
		{
			ymPrompt.errorInfo('请填写姓名',null,null,'错误提示',function(){ymPrompt.close();obj_id.focus();});
			return false;
		}
		action.value = 'add';
	}
	return true;
}
function errMsg(msg)
{
	if(ymPrompt)
		ymPrompt.errorInfo(msg,null,null,'错误提示',function(){ymPrompt.close();frm.login_name.focus();});
}
</script>
</html>
